<form method="post" action="/sys/config/add" enctype="multipart/form-data" class="pageForm required-validate"
      onsubmit="return iframeCallback(this, pageRefresh)">
    <input type="hidden" id="parentId" name="parentId" th:value="${pid}">
    <input type="hidden" id="cmd5" name="cmd5" value="">
    <input type="hidden" id="uid" name="uid" value="">
    <input type="hidden" id="randomData" name="randomData" value="">
    <div class="ibox no-margins no-padding no-borders">
        <div class="ibox-title p-xs ljFixBoxTitle">
            <div class="btn btn-sm btn-primary pull-right" id="btnAddSubmit"><i class="fa fa-paste">添加配置</i></div>
        </div>
        <div style="height:40px;"></div>
        <div class="ibox-content">
            <div class="row">
                <div class="form-group col-md-12">
                    <label>父ID(<b class="text-danger">*</b>):</label>
                    <input type="text" class="form-control input-sm required" th:value="${pid}" readonly>
                </div>
                <div class="form-group col-md-12">
                    <label>配置定义(<b class="text-danger">*</b>):</label>
                    <input name="codeKey" type="text" class="form-control input-sm required" maxlength="32">
                </div>
                <div class="form-group col-md-12">
                    <label>配置值(<b class="text-danger">*</b>):</label>
                    <input name="codeValue" type="text" class="form-control input-sm required">
                </div>
                <div class="form-group col-md-12">
                    <label>配置描述(<b class="text-danger">*</b>):</label>
                    <input name="codeDesc" type="text" class="form-control input-sm required" maxlength="128">
                </div>
                <div class="form-group col-md-12">
                    <label>配置标签(<b class="text-danger">*</b>):</label>
                    <input name="codeTags" type="text" class="form-control input-sm " maxlength="32">
                </div>
                <div class="form-group col-md-12">
                    <label>排序:</label>
                    <input name="codeSort" type="text" class="form-control input-sm required digits" maxlength="4">
                </div>
            </div>
        </div>
    </div>
</form>
<script>
    jQuery(function ($) {
        $("#btnAddSubmit").on("click", function () {
            var values = {};
            modifyVerf(values);
            $("#cmd5").val(values.cmd5);
            $("#uid").val(values.uid);
            $("#randomData").val(values.randomData);
            $(this).closest("form").submit();
        });
    });
</script>